package com.woniuxy.food.client.foodspuclient;

import com.woniuxy.food.client.param.InsertFoodSpuParam;
import com.woniuxy.food.client.param.UpdateFoodSpuParam;
import com.woniuxy.food.client.param.UpdateFoodSpuSalesCountParam;
import com.woniuxy.food.client.param.UpdateFoodSpuStateParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;
import result.Result;

@FeignClient(contextId = "foodSpuManageClient",name = "food")
public interface FoodSpuManageClient {
    @PostMapping("/insertFoodSpu")
    public Result insertFoodSpu(@RequestBody InsertFoodSpuParam param);

    @PutMapping("/updateFoodSpuStateByIds")
    public Result updateFoodSpuStateByIds(@RequestBody UpdateFoodSpuStateParam param);

    @PutMapping("/updateFoodSpuById")
    public Result updateFoodSpuById(@RequestBody UpdateFoodSpuParam param);

    @PutMapping("/updateFoodSpuSalesCountById")
    public Result updateFoodSpuSalesCountById(@RequestBody UpdateFoodSpuSalesCountParam param);

    @DeleteMapping("/deleteFoodSpuByIds")
    public Result deleteFoodSpuByIds(@RequestParam("storeId") Integer storeId,@RequestParam("ids") Integer[] ids);
}
